﻿@{
    Layout = null;
}
@using CNKI.TPI.Web.Admin.Model;
<link href="~/Content/Topic/css/main.css" rel="stylesheet" />

@using CNKI.TPI.Web.Base
@{
    if (ViewBag.SearchResultDoc != null && ViewBag.SearchResultDoc.Rows.Count > 0)
    {
        if (@ViewBag.ShowType == 4)//焦点图
        {
    <script src="~/Content/Topic/js/index.js?jv=2"></script>
            int n = 0;
    <ul>

        @foreach (System.Data.DataRow dr in ViewBag.SearchResultDoc.Rows)
        {
            <li><a target="_blank" href="~/TopicDetail?dbID=@ViewBag.DbID&TopicCode=@ViewBag.TopicCode&dbName=@ViewBag.DbName&sysID=@dr["SYS_FLD_SYSID"]" >
                <img src="@ResourceHelper.GetFirstDigitalPicURL(@ViewBag.DbID, int.Parse(@dr["SYS_FLD_SYSID"].ToString()))" /></a></li>
        }
    </ul>
    <div class="sliderCtr">
        @foreach (System.Data.DataRow dr in ViewBag.SearchResultDoc.Rows)
        {
            if (n == 0)
            {
            <a class="active" href="javascript:void(0);"></a>
            }
            else
            { <a href="javascript:void(0);"></a>
             
            }
            n++;
        }
    </div>
    <div class="sliderCon">
        @foreach (System.Data.DataRow dr in ViewBag.SearchResultDoc.Rows)
        {
            <a target="_blank" href="~/TopicDetail?dbID=@ViewBag.DbID&TopicCode=@ViewBag.TopicCode&dbName=@ViewBag.DbName&sysID=@dr["SYS_FLD_SYSID"]">@dr[0].ToString()</a>
        }
    </div>
    <div class="silderbj"></div>

        }
        else
        {
            int m = 0;
            foreach (System.Data.DataRow dr in ViewBag.SearchResultDoc.Rows)
            {
                if (@ViewBag.ShowType == 1)//文章论文
                {
    <li>
        <a target="_blank" href="~/TopicDetail?dbID=@ViewBag.DbID&TopicCode=@ViewBag.TopicCode&dbName=@ViewBag.DbName&sysID=@dr["SYS_FLD_SYSID"]" class="a w60" title=" @dr[0].ToString()">
            @ColumnAliasHelper.SubContent(@dr[0].ToString(), ViewBag.Len) </a>
            <span class="a w78 fr">@dr["出版时间"]</span>
    </li>

                }
                else if (@ViewBag.ShowType == 2)//画作
                {
    <li>
        <a target="_blank" href="~/TopicDetail?dbID=@ViewBag.DbID&TopicCode=@ViewBag.TopicCode&dbName=@ViewBag.DbName&sysID=@dr["SYS_FLD_SYSID"]">
            <img src="@ResourceHelper.GetFirstSmallPicURL(@ViewBag.DbID, int.Parse(@dr["SYS_FLD_SYSID"].ToString()))" alt="" class="list-img"></a>
    </li>
                }
                else if (@ViewBag.ShowType == 3)//文学作品
                {
    <li>
        <a target="_blank" href="~/TopicDetail?dbID=@ViewBag.DbID&TopicCode=@ViewBag.TopicCode&dbName=@ViewBag.DbName&sysID=@dr["SYS_FLD_SYSID"]">
            <img  src="@ResourceHelper.GetFirstSmallPicURL(@ViewBag.DbID, int.Parse(@dr["SYS_FLD_SYSID"].ToString()))" alt="" class="list-img"></a>
        <a target="_blank" href="~/TopicDetail?dbID=@ViewBag.DbID&TopicCode=@ViewBag.TopicCode&dbName=@ViewBag.DbName&sysID=@dr["SYS_FLD_SYSID"]" class="list-dl-a" title=" @dr[0].ToString()">
            @ColumnAliasHelper.SubContent(@dr[0].ToString(), ViewBag.Len)</a>
    </li>

                }

                else if (@ViewBag.ShowType == 7)//艺术家风采
                {
    <li>
        <a target="_blank" href="~/TopicDetail?dbID=@ViewBag.DbID&TopicCode=@ViewBag.TopicCode&dbName=@ViewBag.DbName&sysID=@dr["SYS_FLD_SYSID"]">
            <img width="148" height="205" src="@ResourceHelper.GetFirstSmallPicURL(@ViewBag.DbID, int.Parse(@dr["SYS_FLD_SYSID"].ToString()))"/>

        </a>

    </li>
                }
                else if (@ViewBag.ShowType == 5)//简介
                {
    <img src="@ResourceHelper.GetFirstSmallPicURL(@ViewBag.DbID, int.Parse(@dr["SYS_FLD_SYSID"].ToString()))" alt="" class="head-pic">
    <div class="intro">
        @foreach (System.Data.DataColumn column in ViewBag.SearchResultDoc.Columns)
        {
            if (!column.ColumnName.StartsWith("SYS_"))
            {
            <p>@column.ColumnName:@dr[column.ColumnName]</p>
            }
        }
        @{SYS_CMS_TOPIC_CLS_QUERY obj = ViewBag.QueryObj;
       
            <a target="_blank" href="~/TopicSingleSearch?name=@obj.DBCode&TopicCode=@ViewBag.TopicCode&displayDBName=@Server.UrlEncode(obj.DBName)
            &topicCLSCode=@obj.CLSCode&topicCLSNodeCode=@obj.NodeCode&autoLoad=1" class="more intro-a">查看全部></a>
        }
    </div>
                
                }

                else if (@ViewBag.ShowType == 6)//影视资料
                {
                    if (m == 0)
                    {
    <div class="video-box">
        <a target="_blank" href="~/TopicDetail?dbID=@ViewBag.DbID&TopicCode=@ViewBag.TopicCode&dbName=@ViewBag.DbName&sysID=@dr["SYS_FLD_SYSID"]">
            <img class="video" src="@ResourceHelper.GetFirstSmallPicURL(@ViewBag.DbID, int.Parse(@dr["SYS_FLD_SYSID"].ToString()))" height="190" width="260" >
        </a>
    </div>
                    }
                    else
                    {
    <ul class="list-tpi bj-s">
        <li><a target="_blank" href="~/TopicDetail?dbID=@ViewBag.DbID&TopicCode=@ViewBag.TopicCode&dbName=@ViewBag.DbName&sysID=@dr["SYS_FLD_SYSID"]" title="@dr[0].ToString()">
            @ColumnAliasHelper.SubContent(@dr[0].ToString(), ViewBag.Len)</a></li>
    </ul>
                    }

                }

                m++;


            }
        }
    }
}
